package com.situ.mall.mapper;

import com.situ.mall.pojo.Product;
import com.situ.mall.pojo.User;
import com.situ.mall.pojo.query.ProductQuery;
import com.situ.mall.pojo.query.UserQuery;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface ProductMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(Product record);

    int insertSelective(Product record);

    Product selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(Product record);

    int updateByPrimaryKey(Product record);

    List<Product> selectByPage(@Param("offset") int offset, @Param("limit") Integer limit, @Param("productQuery") ProductQuery productQuery);
    int selectTotalCount(ProductQuery productQuery);
    int deleteAll(Integer[] ids);
    List<Product> selectByCategoryId(Integer id);
}